using MathematicallySafe.HeadCounter.Data.Common;
using MathematicallySafe.HeadCounter.Data.Interfaces;
using MathematicallySafe.HeadCounter.Data.Models;
using StructureMap;

namespace MathematicallySafe.HeadCounter.ViewModels
{
    public class RaidMemberViewModelBase: ViewModelBase
    {
        private static readonly IGuild Guild = ObjectFactory.GetInstance<IGuild>();

        private string _name;
        private Raider _raider;

        public RaidMemberViewModelBase(string raidingName)
        {
            _name = raidingName;
            _raider = Guild.FindRaider(raidingName);
        }

        public string Name
        {
            get { return _name; }
        }

        public string Identity
        {
            get { return _raider.Identity; }
        }

        public CharacterClass Class
        {
            get { return _raider.Class; }
        }
    }
}